<?php
class My_Form_Decorator_RowDisplayGroup extends Zend_Form_Decorator_Abstract
{
    public function render($content)
    {
        $legend = $this->getElement()->getLegend();
        if(strlen($legend) > 0) {
            $content = '<tr><td colspan="2"><h2>' . $legend . '</h2></td></tr>' . $content;
        }
        return $content;
    }
}